Digital image processing devices, such as digital cameras, use automatic features to increase the quality of an image, such as the preview screen on the digital camera as well as the recorded image and recorded video. This includes the 3A features which refers to automatic white balancing (AWB), automatic focus (AF), and automatic exposure control (AEC). Automatic focus is the automatic adjustment of the lens position relative to an image sensor or other image capture medium to obtain a sharp, clear image.
In a camera system, to get an image without the optical blur, the lens has to be placed in the correct location so the image is focused. Traditionally, for the camera systems of the mobile electronics, such as smartphone and tablet, such a focus location can be predetermined by the typical user cases of the camera, which result in a fixed focus design
Another option uses images taken at different lens distance, and such a location is determined by a “contrast-based” method, which examines the sharpness of the image. In such an example, the best focus position is determined when the sharpest image is obtained. However, this implies taking multiple images from various lens positions, while having the risk of taking extra steps as the lens traverse from front out-of-focus to back out-of-focus, as shown in FIG. 2.
In recent years, a fixed phase detection technique, which uses a particular imaging sensor architecture has been introduced to help speeding up the focusing process. This imaging sensor architecture utilizes a non-removable phase detection mask to pixels mask out half of the light from the imaging sensors. If phase detection pixels from the non-removable phase detection mask are placed with a high density, both defocus direction and displacement can be detected.